<template>
  <div>list列表页</div>
  <el-button v-if="hasPermission('U')">修改</el-button>
  <el-button v-if="hasPermission('C')">增加</el-button>
  <el-button v-if="hasPermission('D')">删除</el-button>
  <el-button v-if="hasPermission('U')">更新</el-button>
  <hr/>
  <el-button v-directive="'C'">创建</el-button>
  <el-button v-directive="'U'">更新</el-button>
  <el-button v-directive="'R'">阅读</el-button>
  <el-button v-directive="'D'">删除</el-button>
<div style="width: 100%;height:20px"></div>
<div class="clipped-box">
  <div class="content">Hello, world!</div>
</div>

</template>

<script setup lang="ts">
import {hasPermission} from "@/utils/hasPemission";
</script>

<style scoped lang="scss">
.clipped-box {
  position: relative;
  width: 200px;
  height: 100px;
  background-color: #007bff;
  clip-path: polygon(0% 20%, 100% 0%, 100% 80%, 0% 100%);
}
.clipped-box::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 20px;
  height: 100%;
  background-color: #007bff;
  border-top-right-radius: 20px;
  border-bottom-right-radius: 20px;
}
.content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 20px;
}



</style>